home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / programm.ing / m2gem106.lzh / CRYSTAL1.06 / DOC / SHORT.TXT < prev    next >
Encoding:
Text File  |  1993-12-18  |  2.6 KB  |  79 lines

  1. short instructions
  2.  
  3. 1. create the directories crystal\ and toolbox\ (on hard disk), e.g.
  4.    as subdirectories to your modula directory
  5.  
  6. 2. copy the "Modula-C" sources from ...\src\crystal\ to the above
  7.    directory crystal\, from ...\src\toolbox\ and ...\src\flying\
  8.    to the above directory toolbox\
  9.  
  10. 3. copy the C-preprocessor cpp from ...\bin\cpp\ and the beautifier
  11.    x2d1 from ...\bin\x2d1\ to a directory where they can be found
  12.    by your prefered shell
  13.  
  14. 4. copy the file ...\inc\crystal.m2h to a directory of your choice
  15.  
  16. 5. fit the shell script c.mup from ...\bin\mupfel\ to your own
  17.    environment. Explanation:
  18.  
  19.    sample call:
  20.  
  21.    c aes.mod HM2
  22.  
  23.  
  24.    contents of c.mup:
  25.  
  26.    echo cpp $1 für $2...
  27.    cpp ~$1 -D$2 -P -imacros C:\USR\INCLUDE\CRYSTAL.M2H > temp
  28.    x2d1 <temp >$1
  29.    rm temp
  30.  
  31.    at this example aes.mod is the name of the source, HM2 is an
  32.    abbreviation for a certain compiler, s. Liste der Modula-
  33.    Compiler in crystal.tex
  34.  
  35.    echo prints the arguments of c.mup (at this example:
  36.    "cpp aes.mod für HM2..."), that means $1 is a variable
  37.    for the source, $2 a variable for the compiler
  38.    (for command.com %1and %2).
  39.    cpp is the C-preprocessor.
  40.    The option -D predefines the target system as a preprocessor
  41.    constant,
  42.    the option -P suppresses confusing comments within the
  43.    output of the preprocessor,
  44.    the option -imacros loads an include file at the calling
  45.    level of the preprocessor. The path of the file crystal.m2h
  46.    has to be fit.
  47.    The preprocessor writes its output to the temporary file
  48.    named temp. x2d1 reads from temp, closing each line with
  49.    cr lf, removing multiple empty lines and writes the result
  50.    to $1.
  51.    Finally temp is deleted.
  52.  
  53. 6. fit the shell script c_all from ...\bin\mupfel\ to your
  54.    environment
  55.  
  56. 7. copy the shell scripts c and c_all to a directory where
  57.    they can be found by your prefered shell
  58.  
  59. 8. start your shell and change directory to that one where
  60.    crystal\ and toolbox\ exist as subdirectories
  61.  
  62. 9. call c_all with the target system as argument
  63.  
  64. 10. make the above directories crystal\ and toolbox\ known
  65.     to your modula system (perhaps copy all files to the
  66.     "work" directory of your modula system)
  67.  
  68. 11. read the patch instructions in ...\cmp\..., esp. for LPRM2
  69.  
  70. 12. start your modula system and compile the files from
  71.     toolbox\ and crystal\ by paying attention to the module
  72.     hierarchy (according to your compiler there are prepared
  73.     "make"-files in ...\cmp\...)
  74.  
  75. 13. try to compile, link and test the module Hello.M2 from
  76.     ...\tst\hello\
  77.  
  78. Good luck!
  79.